﻿Imports System
Imports System.Configuration
Imports System.Collections


''' <summary>
''' RuleSet Collection in the configuration.
''' </summary>
Public Class RuleSetCollection
    Inherits ConfigurationElementCollection

    Public Sub New()
    End Sub

    Protected Overloads Overrides Function CreateNewElement() As ConfigurationElement
        Return New RuleSet(Of String)
    End Function

    Protected Overrides Function GetElementKey(ByVal element As ConfigurationElement) As [Object]
        Return CType(element, RuleSet(Of String)).Name
    End Function

    Default Public Shadows ReadOnly Property Item(ByVal Name As String) As RuleSet(Of String)
        Get
            Return CType(BaseGet(Name), RuleSet(Of String))
        End Get
    End Property

End Class
